public class BankAccount {
    private String acconutNumber;
    private String accountHoldeolderName;
    private float balance;

    public BankAccount(String acconutNumber, String accountHoldeolderName, float balance) {
        this.acconutNumber = acconutNumber;
        this.accountHoldeolderName = accountHoldeolderName;
        this.balance = balance;
    }

    public void deposit(float amount){
        if(amount>0){
            System.out.println("存了"+amount+"元");
            balance = balance+amount;
        }else{
            System.out.println("存款无效");
        }
    }

    public void withdraw(double amount){
        if(amount>0){
            System.out.println("取了"+amount+"元");
        }else{
            System.out.println("取款失败");
        }
    }

    public String getAcconutNumber() {
        return acconutNumber;
    }

    public void setAcconutNumber(String acconutNumber) {
        this.acconutNumber = acconutNumber;
    }

    public String getAccountHoldeolderName() {
        return accountHoldeolderName;
    }

    public void setAccountHoldeolderName(String accountHoldeolderName) {
        this.accountHoldeolderName = accountHoldeolderName;
    }

    public float getBalance() {
        return balance;
    }

    public void setBalance(float balance) {
        this.balance = balance;
    }

    public boolean isOverDraft(){
        if(this.balance<=0){
            return true;
        }else return false;
    }
    public void isVIP(){
        if(this.balance>=100000){
            System.out.println("VIP");
        }else
            System.out.println("普通");
    }
}
